package pl.edu.pb.wi.cookbook.form;

import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

public class NewRecipeForm {
    @NotNull(message = "Wybierz kategorię!")
    private Long category;
    @Size(min = 4, max = 60, message = "Minimum 4 oraz maksimum 60 znaków.")
    private String name;
    @Size(min = 10, max = 255, message = "Minimum 10, maksimum 255 znaków.")
    private String shortDescription;
    @Size(min = 20, message = "Minimum 20 znaków.")
    private String description;
    @Size(min = 5, message = "Minimum 5 znaków.")
    private String ingredients;
    @NotNull(message = "To pole musi być wypełnione.")
    @DecimalMin(value = "1", message = "Minimalna wartośc to 1.")
    @DecimalMax(value = "600", message = "Maksymalna wartość to 600.")
    private Integer prepareTime;
    @NotNull(message = "To pole musi być wypełnione!")
    @DecimalMin(value = "1", message = "Minimalna wartośc to 1.")
    @DecimalMax(value = "15", message = "Maksymalna wartość to 15.")
    private Integer servings;
    private String imageUrl;
    @NotNull(message = "Status przepisu nie może mieć wartości null.")
    private Boolean isPrivate;

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public Long getCategory() {
        return category;
    }

    public void setCategory(Long category) {
        this.category = category;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getShortDescription() {
        return shortDescription;
    }

    public void setShortDescription(String shortDescription) {
        this.shortDescription = shortDescription;
    }

    public String getIngredients() {
        return ingredients;
    }

    public void setIngredients(String ingredients) {
        this.ingredients = ingredients;
    }

    public Integer getPrepareTime() {
        return prepareTime;
    }

    public void setPrepareTime(Integer prepareTime) {
        this.prepareTime = prepareTime;
    }

    public Integer getServings() {
        return servings;
    }

    public void setServings(Integer servings) {
        this.servings = servings;
    }

    public String getImageUrl() {
        return imageUrl;
    }

    public void setImageUrl(String imageUrl) {
        this.imageUrl = imageUrl;
    }

    public Boolean getIsPrivate() {
        return isPrivate;
    }

    public void setIsPrivate(Boolean isPrivate) {
        this.isPrivate = isPrivate;
    }

}
